<template>
  <!-- 头部 公共组件 -->
  <div>
    <el-card class="box-card">
      <div slot="header" class="title-box">
        <span>{{ title }}</span>
        <slot name="btn"></slot>
      </div>

      <slot></slot>
    </el-card>
  </div>
</template>

<script>
export default {
  props: {
    title: {
      type: String,
      default: "标题",
    },
  },
};
</script>

<style lang="less" scoped>
.text {
  font-size: 14px;
}
.item {
  margin-bottom: 18px;
}
.box-card {
  margin: 15px auto 15px auto;
  width: 97%;
}
.title-box {
  display: flex;
  justify-content: space-between;
  line-height: 40px;
  height: 40px;
}

</style>